set(TEST_COMMAND "@TEST_COMMAND@")
message("Running ${TEST_COMMAND}")
execute_process(COMMAND ${TEST_COMMAND} RESULT_VARIABLE CommandResult)
message("Command returned: ${CommandResult}")
if (NOT ("${CommandResult}" EQUAL "0"))
	message(SEND_ERROR ${CommandResult})
else()
	message("Success!")
	message("<CTestMeasurementFile type=\"image/png\" name=\"@TEST_NAME@\">@TEST_OUTPUT_FILE@</CTestMeasurementFile>")
endif()